<!DOCTYPE html>
<html>
<head>
<title>在岗人员列表</title>
<#include "/header.html">
</head>
<body>
<style>
	.avatar-uploader .el-upload {
		border: 1px dashed #d9d9d9;
		border-radius: 6px;
		cursor: pointer;
		position: relative;
		overflow: hidden;
	}
	.avatar-uploader .el-upload:hover {
		border-color: #409EFF;
	}
	.avatar-uploader-icon {
		font-size: 28px;
		color: #8c939d;
		width: 178px;
		height: 178px;
		line-height: 178px;
		text-align: center;
	}
	.avatar {
		width: 178px;
		height: 178px;
		display: block;
	}
</style>

<div id="rrapp">
	<div class="grid-btn">
		<div class="form-group col-sm-2">
			<input type="text" class="form-control" v-model="q.empName" @keyup.enter="query" placeholder="员工名">
		</div>
		<a class="btn btn-default" @click="query">查询</a>
		<a class="btn btn-primary" @click="openDialog">改变岗位状态</a>
		<el-dialog title="选择状态与原因" :visible.sync="dialogFormVisible">
			<el-form >
				<el-form-item label="状态" :label-width="formLabelWidth">
					<el-select v-model="status" placeholder="请选择">
						<el-option
								v-for="item in statusType"
								:key="item.value"
								:label="item.label"
								:value="item.value">
						</el-option>
					</el-select>
				</el-form-item>
				<el-form-item label="原因" :label-width="formLabelWidth">
					<el-select v-model="cause" placeholder="请选择">
						<el-option
								v-for="item in causes"
								:key="item.value"
								:label="item.label"
								:value="item.value">
						</el-option>
					</el-select>
				</el-form-item>
				<el-form-item label="离岗时间" :label-width="formLabelWidth">
					<el-col >
						<el-date-picker
								type="date"
								value-format="yyyy-MM-dd"
								placeholder="选择日期"
								v-model="changeDate">
						</el-date-picker>
					</el-col>
				</el-form-item>
				<el-form-item label="审批人" :label-width="formLabelWidth">
					<el-input v-model="name"></el-input>
				</el-form-item>
				<el-form-item label="选择附件" :label-width="formLabelWidth">
						<el-upload
								class="avatar-uploader"
								ref="upload"
								action="../../fun/emp/upLoad"
								:on-success="handleAvatarSuccess"
								:before-upload="beforeAvatarUpload"
								:limit="1"
								:auto-upload="false">
						</el-upload>
					<el-button style="margin-left: 10px;" size="small" type="success" @click="submitUpload">上传到服务器</el-button>

				</el-form-item>
			</el-form>
			<div slot="footer" class="dialog-footer">
				<el-button @click="dialogFormVisible = false">取 消</el-button>
				<el-button type="primary" @click="changeStatus">确 定</el-button>
			</div>
		</el-dialog>
	</div>
    <table id="jqGrid"></table>
    <div id="jqGridPager"></div>
</div>

<script src="${request.contextPath}/statics/js/modules/function/emp_exist.js?_${.now?long}"></script>
</body>
</html>